import RouteComponent from "./components";
import { Redirect } from 'react-router-dom';

const routes = [
  {
    path: "/login",
    meta: { title: "登录" },
    component: RouteComponent.Login
  },
  {
    path: "/",
    meta: { title: "Layout" },
    component: RouteComponent.Layout,
    routes: [
      {
        path: '/',
        exact: true,
        meta: { title: "首页" },
        render: () => <Redirect to="/home" />
      },
      {
        path: '/home',
        meta: { title: "首页" },
        component: RouteComponent.Home
      },
    ]
  },
]
export default routes;